cmake_minimum_required(VERSION 2.8 FATAL_ERROR)

find_package(LibTimeutils REQUIRED)
include_directories(${LibTimeutils_INCLUDE_DIRS})
set(LIBS ${LibTimeutils_LIBRARIES})

find_package(LibGenutils REQUIRED)
include_directories(${LibGenutils_INCLUDE_DIRS})
list(APPEND LIBS ${LibGenutils_LIBRARIES})

add_executable(l1bextract_meris
  l1bextract_meris.cpp
  EnvsatFile.cpp
  EnvsatMPH.cpp
  EnvsatSPH.cpp
  EnvsatDSD.cpp
  EnvsatDSR.cpp
  EnvsatUtil.cpp
  MerisSPH.cpp
  TiepointDSR.cpp
  MeasurementDSR.cpp
  RadianceDSR.cpp
  FlagsDSR.cpp
)

target_link_libraries(l1bextract_meris ${LIBS})

install (TARGETS l1bextract_meris DESTINATION bin)
